﻿//Created by Action Script Viewer - http://www.buraks.com/asv
package Modules.guide.actions {
    import Display.*;

    public class GAShowNews extends GuideAction {

        protected var m_locPrefix:String = "";
        protected var m_newsImage:String = "";

        override public function createFromXml(_arg1:XML):Boolean{
            var _local2:XMLList = checkAndGetElement(_arg1, "news");
            if (!_local2){
                return (false);
            };
            this.m_locPrefix = String(_local2.@locname);
            this.m_newsImage = String(_local2.@url);
            if ((((this.m_newsImage == null)) || ((this.m_newsImage.length == 0)))){
                return (false);
            };
            return (true);
        }
        override public function update(_arg1:Number):void{
            super.update(_arg1);
            var _local2:String = ZLoc.t("Tutorials", (this.m_locPrefix + "_newsTitle"));
            var _local3:String = ZLoc.t("Tutorials", (this.m_locPrefix + "_newsContent"));
            var _local4:String = ZLoc.t("Tutorials", (this.m_locPrefix + "_newsSubHead"));
            UI.displayNewsFlash(_local3, 0, this.m_newsImage, _local4, _local2, true);
            removeState(this);
        }

    }
}//package Modules.guide.actions 
